package com.cnc.ssm.model;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

import java.io.Serializable;

/**
 * @author Hibernate CodeGenerator
 */
public class PwSqSetting implements Serializable {

    /**
     * identifier field
     */
    private String sqId;

    /**
     * nullable persistent field
     */
    private Integer blockCount;

    /**
     * nullable persistent field
     */
    private Integer sqLen;

    /**
     * full constructor
     */
    public PwSqSetting(java.lang.String sqId, java.lang.Integer blockCount, java.lang.Integer sqLen) {
        this.sqId = sqId;
        this.blockCount = blockCount;
        this.sqLen = sqLen;
    }

    /**
     * default constructor
     */
    public PwSqSetting() {
    }

    /**
     * minimal constructor
     */
    public PwSqSetting(java.lang.String sqId) {
        this.sqId = sqId;
    }

    public java.lang.String getSqId() {
        return this.sqId;
    }

    public void setSqId(java.lang.String sqId) {
        this.sqId = sqId;
    }

    public java.lang.Integer getBlockCount() {
        return this.blockCount;
    }

    public void setBlockCount(java.lang.Integer blockCount) {
        this.blockCount = blockCount;
    }

    public java.lang.Integer getSqLen() {
        return this.sqLen;
    }

    public void setSqLen(java.lang.Integer sqLen) {
        this.sqLen = sqLen;
    }

    public String toString() {
        return new ToStringBuilder(this)
                .append("sqId", getSqId())
                .toString();
    }

    public boolean equals(Object other) {
        if (!(other instanceof PwSqSetting)) return false;
        PwSqSetting castOther = (PwSqSetting) other;
        return new EqualsBuilder()
                .append(this.getSqId(), castOther.getSqId())
                .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
                .append(getSqId())
                .toHashCode();
    }

}
